package com.cgsrp.cgsrp_community.dao;

import com.cgsrp.cgsrp_community.domain.Blog;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface BlogMapper {
    int deleteByPrimaryKey(Integer id);

    int insert(Blog record);

    int insertSelective(Blog record);

    Blog selectByPrimaryKey(Integer id);

    int updateByPrimaryKeySelective(Blog record);

    int updateByPrimaryKey(Blog record);

    List<Blog> list();

    List<Blog> glist(int userId);

    void increaseLevelByLike(Integer blogId);

    void reduceLevelByLike(Integer blogId);

    List<Blog> selectBlogByCreatBy(@Param("userId") int userId, @Param("searchKey") String searchKey);
}
